<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head>
    <th:block th:include="include :: header('修改教师管理')" />
</head>
<body class="white-bg">
    <div class="wrapper wrapper-content animated fadeInRight ibox-content">
        <form class="form-horizontal m" id="form-teacher-edit" th:object="${eudTeacher}">
            <input name="id" th:field="*{id}" type="hidden">
            <div class="form-group">    
                <label class="col-sm-3 control-label">教师：</label>
                <div class="col-sm-8">
                    <input name="tname" th:field="*{tname}" class="form-control" type="text">
                </div>
            </div>
            <div class="form-group">    
                <label class="col-sm-3 control-label">工号：</label>
                <div class="col-sm-8">
                    <input name="num" th:field="*{num}" class="form-control" type="text">
                </div>
            </div>

            <div class="form-group">
                <label class="col-sm-3 control-label">职称：</label>
                <div class="col-sm-8">
                    <select name="zhicheng" class="form-control m-b" th:with="type=${@dict.getType('tea_zhicheng')}">
                        <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}" th:field="*{zhicheng}"></option>
                    </select>
                </div>
            </div>
            <div class="form-group">
                <label class="col-sm-3 control-label">科目：</label>
                <div class="col-sm-8">
                    <label th:each="c:${courses}" class="check-box">
                        <input name="courses" type="checkbox" th:value="${c.id}" th:text="${c.cname}" th:checked="${c.flag}">
                    </label>
                </div>
            </div>




        </form>
    </div>
    <th:block th:include="include :: footer" />
    <script th:inline="javascript">
        var prefix = ctx + "system/teacher";
        $("#form-teacher-edit").validate({
            focusCleanup: true
        });

        function submitHandler() {
            if ($.validate.form()) {
                $.operate.save(prefix + "/edit", $('#form-teacher-edit').serialize());
            }
        }
    </script>
</body>
</html>